package org.example.rsy.service.impl;

import org.apache.tika.sax.ToHTMLContentHandler;
import org.example.rsy.service.BaseTikaService;
import org.springframework.stereotype.Service;
import org.xml.sax.ContentHandler;

@Service
public class FormattedTextTikaService extends BaseTikaService {

    @Override
    public ContentHandler initHandler() {
        return new ToHTMLContentHandler();
    }



    @Override
    public String extractData() {
        return getHandler().toString();
    }

    @Override
    public int getCode() {
        return 2;
    }
}
